Included within your XML Instance Samples folder (Program Files...Extensibility...XI11...Samples) are a number of sample documents which you can use to begin exploring the various features and functions of XML Instance. To demonstrate some of the display customization features of XML Instance, the samples folder includes two files, each depicting a different view of the same business document (in this case, a job posting). The first version depicts the standard view of the document, while the second version shows the same document with the display formatted to facilitate a specific task.
To see the different views firsthand, use XML Instance to open the document entitled posting1.xml found in the Samples folder. (This document is adapted from the HR-XML Consortium's sample job posting document contributed to the schema repository at www.biztalk.org ). The posting1.xml file represents the standard vertical display of elements and attributes and their corresponding data. This view, offering a clear and thorough display of the overall document hierarchy, is effective when in the process of building a new document or when making major modifications to a document. (Feel free to practice adding new elements and attributes.)
Assume, however, that this existing document requires periodic updating to only a very specific area, for example the job description information. Now use XML Instance to open the second version of this file, posting2.xml. The display for this file has been customized to allow easier recognition of the various job description fields, and, consequently to allow for easier data entry. Notice that despite the dramatically different views presented by the two files files, the actual source view for these documents remains identical.
The techniques used in customizing the posting2.xml display, included:
To gain greater experience with these and other techniques, take the Quick Tour which leads you step by step through the creation of a new document.
The Samples folder includes some XSLT stylesheets designed to transform XML documents into HTML. To demonstrate how stylesheets can be applied within XML Instance, open the XML document called invoice1.xml. From the Stylesheet menu, select the Set Stylesheet and choose Select. Browse to the Samples folder and select the file called invoice1.xsl. This stylesheet transforms the XML tags of invoice1.xml into HTML tags (specifically XHTML) to produce an invoice-like display in a web browser. To see the results from the transformation, select Preview from the Stylesheet menu.
Note: To view the best display, set your preferences to use a web browser in place of the internal java browser.
To make changes to your stylesheet, choose Edit Stylesheet from the Stylesheet menu. To view or make changes to the document which results from the transformation, choose Transform from the Stylesheet menu.
To learn more about creating and implementing XSLT styleheets, visit http://www.w3.org/Style/XSL/ .